package com.baosight.risk.web.riwa;

import com.baosight.risk.api.riwa.RiwaEhrContractService;
import com.baosight.risk.base.controller.BaseController;
import com.baosight.risk.common.result.AjaxResult;
import com.baosight.risk.common.utils.StringUtils;
import com.baosight.risk.service.riwa.entity.RiwaEhrContract;
import com.baosight.risk.service.zbaa.entity.ZbaaTarget;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;
import javax.ws.rs.core.MediaType;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.List;

/**
 * @author Liuhaonan
 * @date 2020年 05月07日 10:26:01
 * @describe Ehr合同考核扣分
 */
@Slf4j
@RestController
@RequestMapping("/riwa/ehrContract")
@Api(value = "ehr合同考核扣分", description = "ehr合同考核扣分", produces = MediaType.APPLICATION_JSON)
public class RiwaEhrContractController extends BaseController {
    @Autowired
    RiwaEhrContractService riwaEhrContractService;

    /**
     * 分页查询ehr合同扣分
     *
     * @param task
     * @return
     */
    @GetMapping("list")
    @ApiOperation("分页查询ehr合同扣分")
    public AjaxResult select(RiwaEhrContract task){
        startPage();
        List<RiwaEhrContract> list = riwaEhrContractService.getEhrContractList(task);
        return getResultPage(list);
    }

}
